package ${package.Parent}.domain.co;

<#if springdoc>
import io.swagger.v3.oas.annotations.media.Schema;
<#elseif swagger>
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
</#if>
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotNull;
<#if entityLombokModel>
import lombok.Getter;
import lombok.Setter;
    <#if chainModel>
import lombok.experimental.Accessors;
    </#if>
</#if>


/**
 * <p>
 * ${table.comment!}
 * </p>
 *
 * @author ${author}
 * @since ${date}
 */
<#if entityLombokModel>
@Getter
@Setter
    <#if chainModel>
@Accessors(chain = true)
    </#if>
</#if>
<#if springdoc>
@Schema(description = "${table.comment!}更新参数")
<#elseif swagger>
@ApiModel(description = "${table.comment!}更新参数")
</#if>
public class ${entity?replace('Entity', 'UpdateCo')} {
<#if entitySerialVersionUID>

    private static final long serialVersionUID = 1L;
</#if>

    @NotNull(message = "id不能为空")
    @Min(value = 1, message = "id不能小于1")
    <#if springdoc>
    @Schema(description = "数据ID")
    <#elseif swagger>
    @ApiModelProperty("数据ID")
    <#else>
    /**
    * 数据ID
    */
    </#if>
    private Long id;
<#-- ----------  BEGIN 字段循环遍历  ---------->
<#list table.fields as field>

    <#if field.comment!?length gt 0>
        <#if springdoc>
    @Schema(description = "${field.comment}")
        <#elseif swagger>
    @ApiModelProperty("${field.comment}")
        <#else>
    /**
     * ${field.comment}
     */
        </#if>
    </#if>
    private ${field.propertyType} ${field.propertyName};
</#list>

}
